package ${package}.pojo;

import com.baomidou.mybatisplus.annotation.*;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import com.hifar.plat.AopOption.Dict;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.alibaba.fastjson.annotation.JSONField;
import lombok.Data;
import java.util.Date;
import lombok.EqualsAndHashCode;
import java.io.Serializable;

/**
* <p>
* ${table.comment!}
* </p>
*
* @author ${author}
* @since ${date}
*/
@Data
@EqualsAndHashCode(callSuper = false)
@TableName("${table.name}")
@ApiModel(value = "${entity}对象", description = "${table.comment!}")
public class ${entity} implements Serializable{

    private static final long serialVersionUID = 1L;

<#-- ----------  BEGIN 字段循环遍历  ---------->
<#list table.fields as field>

    /**
    * ${field.comment}
    */
    @ApiModelProperty(value = "${field.comment}")
    <#if field.hasDict>
    @Dict(dictCode = "${field.dictField}")
    </#if>
    <#if field.isDate>
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    </#if>
    <#if field.keyFlag>
    @TableId("${field.annotationColumnName}")
    <#elseif field.fill??>
    @TableField(value = "${field.annotationColumnName}", fill = FieldFill.${field.fill})
    <#elseif field.convert>
    @TableField("${field.annotationColumnName}")
    </#if>
    @JSONField(name = "${field.propertyName}")
    private ${field.propertyType} ${field.propertyName};
</#list>
<#------------  END 字段循环遍历  ---------->
}